package com.tizona.dao;

import com.tizona.entity.*;
import com.tizona.entity.TransactionSessionTraffic;

import java.sql.SQLException;
import java.util.Set;
import java.util.Calendar;
import java.util.HashSet;
import java.util.HashMap;


public interface SessionDAO extends BaseDAO  {

    public void SaveOrUpdate(Transaction tran) throws SQLException;

    public void SaveOrUpdate(TransactionSessionTraffic tran) throws SQLException;

    public void SaveOrUpdate(Session session) throws SQLException;

    public HashSet<Session> getActiveSessions(Se se, final Calendar model_time);

    public HashMap<Long,SessionTraffic> getSessionTraffic(Session session) throws SQLException;

    public Set<Chunk> getActiveChunks(Session session) throws SQLException;

    public void makeTransaction(Transaction trans) throws SQLException;

    public void clearTempSession(Session session) throws SQLException;

    public void beginTransaction() throws SQLException;

    public void commitTransaction() throws SQLException;

    public void rollbackTransaction() throws SQLException;

    public HashSet<Session> loadSessions(Se se);

}
